package com.ysactive.util;

import cn.hutool.core.util.RandomUtil;

import java.util.ArrayList;
import java.util.List;

/**
 * Notice:
 *
 * @author xuxu
 * @version 1.0
 * @date 2023/9/2
 * @since 1.0
 */
public class YsUtil {

    public static String getyzm() {
        return RandomUtil.randomString(6);
        /*
        char[] arrays = new char[6];
        for (int i = 0; i < 6; i++) {
            int num = (int) Math.floor(Math.random() * 58) + 65;
            if (num > 90 && num < 97) {
                num = (int) Math.floor(Math.random() * 10);
                arrays[i] = Integer.toString(num).charAt(0);
                continue;
            }
            arrays[i] = (char) num;
        }
        return new String(arrays);
         */
    }
    public static Boolean checkType(String type){
        List<String> typeList=new ArrayList<>();
        typeList.add("01");
        typeList.add("02");
        typeList.add("03");
        typeList.add("04");
        return typeList.contains(type);
    }
}
